class Person():
    def __init__(self, name, gender, age, weight):
        self.name = name
        self.gender = gender
        self.age = age,
        self.__weight = weight
        self.address = []
    
    def tell(self):
        print('我叫{}, 性别：{}, 年龄：{}岁, 体重{}斤'.format(self.name, self.gender, self.age, self.__tell_weight()))

    def __tell_weight(self):
        return self.__weight

class Stu(Person):

    def __init__(self, name, gender, age, weight, major):
        Person.__init__(self, name, gender, age, weight)
        self.major = major

    def tell(self):
        print('我叫{}, 性别：{}, 年龄：{}岁,  专业是{}'.format(self.name, self.gender, self.age,  self.major))

p1 = Person('张三', '女', 20, 89)
# p1.name = '张三'
p1.address.append('吉林四平')
p1.tell()
print(p1.address)

stu1 = Stu('李四', '男', 19, 100, '软件工程')
print(stu1.major)
stu1.tell()

